package main

import (
	"log"

	"gitee.com/xuender/pp/robot"
)

func main() {
	s := robot.NewService()

	s.Add(func(s string) string { return s }, "测试命令", "测试", "test", "t")

	log.Println("?")
	log.Println(s.Call("?"))
	log.Println("help")
	log.Println(s.Call("help"))
	log.Println("help 帮助")
	log.Println(s.Call("help 帮助"))
	log.Println("help ？")
	log.Println(s.Call("help ？"))

	log.Println("call t")
	log.Println(s.Call("t"))
	log.Println("call ! date")
	log.Println(s.Call("! date"))
	log.Println("call !ls /tmp")
	log.Println(s.Call("!ls /tmp"))
}
